/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package bluetooth;

import javax.microedition.lcdui.Display;
import javax.microedition.midlet.MIDlet;

/**
 *
 * @author wssccc
 */
public class BlueCanvasBuilder implements Runnable {

    MIDlet m_instance = null;
    BlueCanvasBase canvas;

    /*
     * @canvas:canvas
     * @MIDlet:instance
     */
    public BlueCanvasBuilder(BlueCanvasBase canvas, MIDlet instance) {
        m_instance = instance;
        this.canvas = canvas;


    }

    public void run() {


        canvas.setBlueComm(new BlueUtil(m_instance).createBluetoothConnection());
        Display.getDisplay(m_instance).setCurrent(canvas);



    }
}
